<!doctype html>
<html>
<head>
<meta name="apple-mobile-web-app-capable" content="yes">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0">
<title>救援</title>
<link href="../../css/newStyle.css" type="text/css" rel="stylesheet" />
<script type="text/javascript" src="../../js/jquery-1.4.2.js"></script>
<script type="text/javascript" src="../../js/common.js"></script>
<script type="text/javascript" src="../../js/gbRst.js"></script>
<script type="text/javascript" src="../../js/utils.js"></script>
<script type="text/javascript" src="../../js/openId.js"></script>
<script type="text/javascript" src="../../js/header&footer.js"></script>
<script type="text/javascript" src="../../js/carService.js"></script>
<script type="text/javascript" src="../../js/ad.js"></script>
<script type="text/javascript" src="../../js/swipe.js"></script>
<script type="text/javascript" src="../../js/qmsk-1.1.js"></script>
<script type="text/javascript" src="../../js/addReadNum.js"></script>
<script type="text/javascript">
$(function(){
	loadAd("banner",6)
	getall();

	/* new qmsk.SiglePinterest({
		url : '../../../carLesson/find/adList', // 请求地址，插件会自动在 url 后追加 /n/n
		initPage : 1, // 首次加载页数
		size : 1, // 每次加载数量，即每页的大小
		success : printDataToPage, // 成功回调
		valves : 100 ,//当滚动条距离底部该像素的时候加载
		data:{'typeId':2,'shopId':_shopId}
	}); */
})

/**
 * 将查询返回的数据显示到页面上，参数是服务器返回的查询报文，json对象
 */
/* function printDataToPage(dt) {
	var htm="";
	for ( var i = 0; i < dt.row; i++) {
		var index= dt.getValue("indexUrl",i) 
		var flag= false;
		if(IsEmpty(index)){
			flag=true
		}
	 htm+="<dl onclick='toS("+dt.getValue("id",i)+","+flag+")' class=\"shopInside news\"><dt><img src=\""+dt.getValue("imageUrl",i)+"\"></dt><dd><strong class=\"title\">"+dt.getValue("title",i)+"</strong><p>"+dt.getValue("memo",i)+" </p></dd></dl>"
	}
	$("#info").append(htm)
	format("shopInside","28","26","14","12");

} */
	//分页和其他
	//pagination(message.result.len);
	//$("#sup").html('共 ' + message.result.len + ' 条');


function getall(){
	$.ajax({
		url:'../../../carLesson/find/adList',
		type:'get',
		async:false,
		data:{'typeId':6,'shopId':_shopId},
		success:function(data){
			var dt = JSON.parse(data);
			var nameList= new Array();
			if(dt.state==0){
					for(var i = 0;i<dt.result.data.length;i++){
					var keyWord = getHtmlString(getHeadIndexValue(i, dt, "keyWord"))
					var index= getHtmlString(getHeadIndexValue(i, dt, "indexUrl"))
					var flag= false;
					if(IsEmpty(index)){
						flag=true
					}
					var dl="<dl onclick=\"toS(\'"+getHtmlString(getHeadIndexValue(i, dt, "indexUrl"))+"\',"+flag+","+getHtmlString(getHeadIndexValue(i, dt, "id"))+")\" class=\"shopInside news\"><dt><img src=\""+getHtmlString(getHeadIndexValue(i, dt, "imageUrl"))+"\"></dt><dd><strong class=\"title\">"+getHtmlString(getHeadIndexValue(i, dt, "title"))+"</strong><p>"+getHtmlString(getHeadIndexValue(i, dt, "memo"))+" </p></dd></dl>"
					if(nameList.length>0){
						var flag2= false;
						var s=0
					for ( var j = 0; j < nameList.length; j++) {
						if(keyWord==nameList[j]){
							flag2=true
							s=j
						}
					}
					if(flag2){
						$("#info_"+s).append(dl);
					}else{
						nameList.push(keyWord);
						var htm = "<h2 class=\"xilie\"><span>"+keyWord+"</span></h2>"+
						"<div id='info_"+(nameList.length-1)+"' >"+dl
						"</div>"	
						$("#allInfo").append(htm)
					}
					}else{
						nameList.push(keyWord);
					var htm = "<h2 class=\"xilie\"><span>"+keyWord+"</span></h2>"+
					"<div id='info_0' >"+dl
					"</div>"	
						$("#allInfo").append(htm)
					}
					
				}

				}
		}
	});
}


function toS(url,flag,id){
	if(flag){
		return false;
	}else{
		_addReadNmber(id, url);
	}
}
</script>
</head>

<body>
<div class="wrapper">
  <div class="container scrollBar">
  	<!--广告-->
    <div id='banner' class='swipe'>
      <!-- <div class='swipe-wrap'>
        <div class="ad"><img src="../../images/ban1.jpg" />
          <p>会员</p>
        </div>
        <div class="ad"><img src="../../images/ban2.jpg" />
          <p>俱乐部</p>
        </div>
        <div class="ad"><img src="../../images/ban3.jpg" />
          <p>优惠券</p>
        </div>
      </div> -->
    </div>
    <!--广告over-->
  <!--   <h2 class="xilie"><span>一汽大众</span><a class="more">更多&gt;&gt;</a></h2>
    <dl class="shopInside" onClick="redirectUrl('carShowDet.html')">
    	<dt><img src="../../images/img1.jpg"></dt>
        <dd>
        	<strong class="title">一汽大众</strong>
            <p>酿造拉菲酒的苛刻标准使拉菲副牌红具有了与正牌相近的品质。浓郁的果味使其口感温和特久，带有顺滑、典雅、柔和的单宁，相当平衡，回味悠长，有着独特的个性。</p>
            <b>商城价：<span class="red dolor">￥56000.00</span></b>
        </dd>
    </dl>
    <dl class="shopInside" onClick="redirectUrl('carShowDet.html')">
    	<dt><img src="../../images/img1.jpg"></dt>
        <dd>
        	<strong class="title">一汽大众</strong>
            <p>酿造拉菲酒的苛刻标准使拉菲副牌红具有了与正牌相近的品质。浓郁的果味使其口感温和特久，带有顺滑、典雅、柔和的单宁，相当平衡，回味悠长，有着独特的个性。</p>
            <b>商城价：<span class="red dolor">￥56000.00</span></b>
        </dd>
    </dl>
    <dl class="shopInside" onClick="redirectUrl('carShowDet.html')">
    	<dt><img src="../../images/img1.jpg"></dt>
        <dd>
        	<strong class="title">一汽大众</strong>
            <p>酿造拉菲酒的苛刻标准使拉菲副牌红具有了与正牌相近的品质。浓郁的果味使其口感温和特久，带有顺滑、典雅、柔和的单宁，相当平衡，回味悠长，有着独特的个性。</p>
            <b>商城价：<span class="red dolor">￥56000.00</span></b>
        </dd>
    </dl>
    <dl class="shopInside" onClick="redirectUrl('carShowDet.html')">
    	<dt><img src="../../images/img1.jpg"></dt>
        <dd>
        	<strong class="title">一汽大众</strong>
            <p>酿造拉菲酒的苛刻标准使拉菲副牌红具有了与正牌相近的品质。浓郁的果味使其口感温和特久，带有顺滑、典雅、柔和的单宁，相当平衡，回味悠长，有着独特的个性。</p>
            <b>商城价：<span class="red dolor">￥56000.00</span></b>
        </dd>
    </dl>
    <dl class="shopInside" onClick="redirectUrl('carShowDet.html')">
    	<dt><img src="../../images/img1.jpg"></dt>
        <dd>
        	<strong class="title">一汽大众</strong>
            <p>酿造拉菲酒的苛刻标准使拉菲副牌红具有了与正牌相近的品质。浓郁的果味使其口感温和特久，带有顺滑、典雅、柔和的单宁，相当平衡，回味悠长，有着独特的个性。</p>
            <b>商城价：<span class="red dolor">￥56000.00</span></b>
        </dd>
    </dl> -->
    <div id="allInfo"></div>
  </div>
</div>
<!--截取字符串--> 
</body>
</html>
